{include file="common/header" /}

<body>
<head>
 {include file="common/personal_top" /}
<!--用户中心收藏样式-->
<div class="user_style clearfix">
 <div class="user_center clearfix">
     {include file="common/center" /}
 </div>
 <!--收藏样式-->
  <div class="right_style">
  <div class="title_style"><em></em>我的收藏</div> 
  <div class="Favorites_slideTxtBox">
     <div class="hd"><ul><li>收藏的商品</li></ul></div>
     <div class="bd">
        <ul class="commodity_list clearfix">
         <div class="Number_Favorites">共收藏：{$collects|count}条</div>
         <div class="clearfix">
            {volist name="collects" id="vo"}
            <li class="collect_p">
              <em class="iconfont  delete"></em>
              <a href="javascript:void(0)" attr-id="{$vo.gid}" class="buy_btn">立即购买</a>
              <div class="collect_info">
                <div class="img_link"> <a href="#" class="center "><img src="{$vo.picture}"></a></div>
                <dl class="xinxi">
                <dt><a href="{:url('goods/goods_detail',['id'=>$vo.gid])}" class="name">{$vo.gname}</a></dt>
                <dd><span class="Price"><b>￥</b>{$vo.price}</span></dd>         
                </dl>
            </div>
            </li>
            {/volist}
       </div>
       <div class="Paging">
    <div class="Pagination">
    <a href="#">首页</a>
     <a href="#" class="pn-prev disabled">&lt;上一页</a>
	 <a href="#" class="on">1</a>
	 <a href="#">2</a>
	 <a href="#">3</a>
	 <a href="#">4</a>
	 <a href="#">下一页&gt;</a>
	 <a href="#">尾页</a>	
     </div>
    </div>
        </ul>
     </div>
   </div>
<script>
$(function(){
    $('.collect_p .buy_btn').each(function(){
        url = "{:url('order/collection_pay')}";
        $(this).click(function(){
          gid = $(this).attr('attr-id');
          data = {'gid':gid};
          $.post(url,data,function(result){
              if(result.code == 1) {
                location.href = result.data;
              }else {
                  alert(result.msg);
              }
          },'json');
        }) 
    })
})
</script>
<script>
jQuery(".Favorites_slideTxtBox").slide({trigger:"click"});
</script>
  </div>
 </div>
</div>
 {include file="common/footer" /}
</body>
</html>
